package com.eatables.service;

import java.io.IOException;

import javax.servlet.ServletException;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import com.eatables.dao.EatablesMasterDao;

public class EatablesIKnowImpl extends HttpServlet implements EatablesIKnowIfc {

	/**
    * 
    */
	private static final long serialVersionUID = 1L;
	public String name;
	public String address;
	public String lat;
	public String lng;
	public String type;

	public void doGet(HttpServletRequest request, HttpServletResponse response)
			throws ServletException, IOException {
		EatablesMasterDao masterDao = new EatablesMasterDao();
		String rname = request.getParameter("rname");
		String type = request.getParameter("type");
		String lng = request.getParameter("lng");
		String lat = request.getParameter("lat");
		String phone = request.getParameter("phone");
		String descr = request.getParameter("descr");
		String address = request.getParameter("address");
		String musthav = request.getParameter("musthav");
		String name = request.getParameter("name");
		String mailid = request.getParameter("mailid");
		

		System.out.println("Ganesh IKnow");
		System.out.println("rname " + rname);
		System.out.println("type " + type);
		System.out.println("lng" + lng);
		System.out.println("lat" + lat);
		System.out.println("descr" + descr);
		System.out.println("phone" + phone);
		System.out.println("address " + address);
		System.out.println("musthav " + musthav);
		System.out.println("name " + name);
		System.out.println("mailid " + mailid);

		masterDao.setHotelData(rname, type, lng, lat, address, phone, descr, musthav,name, mailid);
		System.out.println("SUCCESS         ");
	}

	public String getAddress() {
		return address;
	}

	public void setAddress(String address) {
		this.address = address;
	}

	public String getLat() {
		return lat;
	}

	public void setLat(String lat) {
		this.lat = lat;
	}

	public String getLng() {
		return lng;
	}

	public void setLng(String lng) {
		this.lng = lng;
	}

	public String getType() {
		return type;
	}

	public void setType(String type) {
		this.type = type;
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public String insertHotelDetails() {
		// TODO Auto-generated method stub
		return null;
	}

}
